Skip to content

Make repeat emit Utf8View for Utf8View input#20612

Open
kumarUjjawal wants to merge 1 commit intoapache:mainfrom
kumarUjjawal:refactor/repeat_utf8view
Open

Make repeat emit Utf8View for Utf8View input#20612
kumarUjjawal wants to merge 1 commit intoapache:mainfrom
kumarUjjawal:refactor/repeat_utf8view

Conversation

@kumarUjjawal
Copy link
Contributor

Which issue does this PR close?

Part of #20585

Rationale for this change

String UDFs should preserve string representation where feasible. repeat previously accepted Utf8View input but emitted Utf8, causing an unnecessary type downgrade. This aligns repeat with the expected behavior of returning the same string type as its primary input.

What changes are included in this PR?

  1. Updated repeat return type inference to emit Utf8View when input is Utf8View, while preserving existing behavior for Utf8 and LargeUtf8.
  2. Added tests

Are these changes tested?

Yes

Are there any user-facing changes?

No

@github-actions github-actions bot added sqllogictest SQL Logic Tests (.slt) functions Changes to functions implementation labels Feb 28, 2026
@Omega359
Copy link
Contributor

Omega359 commented Mar 2, 2026

Apparently I did a PR for the same change without realizing it #20645 Reviewers can select which of these PR's should be merged in.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

functions Changes to functions implementation sqllogictest SQL Logic Tests (.slt)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants